home *** CD-ROM | disk | FTP | other *** search
/ Champak 120 / Vol 120.iso / games / titans / game.swf / scripts / frame_61 / DoAction.as
Text File  |  2010-11-09  |  642b  |  26 lines

  1. delete onenterframe;
  2. fadescreen();
  3. gamename = ["raven","cyborg","star","beastboy","robin"];
  4. loadMovie(gamename[rt.op - 1] + ".swf",place);
  5. onenterframe = function()
  6. {
  7.    persen = math.floor(place.getBytesLoaded() / place.getBytesTotal() * 100);
  8.    if(place.getBytesLoaded() == place.getBytesTotal())
  9.    {
  10.       gotoAndPlay(62);
  11.    }
  12.    barcount = 30;
  13.    cnt = math.floor(persen / 100 * barcount);
  14.    if(cnt > 0 and cnt <= barcount)
  15.    {
  16.       var i = 1;
  17.       while(i <= cnt)
  18.       {
  19.          ins.lbar["bar" + i].gotoAndStop(3);
  20.          i++;
  21.       }
  22.       ins.lbar["bar" + (cnt + 1)].gotoAndStop(2);
  23.    }
  24. };
  25. stop();
  26.